import React from 'react'
import {
    useLocation,
    useParams,
    useNavigate
} from 'react-router-dom'
function without(Com) {
  return (props)=>{
        const location=useLocation()
        const params=useParams()
        const navigate=useNavigate()
        return <Com {...props} router={{navigate,params,location}}></Com>
  }
}

export default without